#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>
#include <QComboBox>
#include <QPushButton>
#include <QDebug>
#include <QHBoxLayout>

#include "uidesign.h"
#include "setserialparam.h"
#include "serialdebug.h"
#include "serialprotocol.h"
#include "serialanalysedata.h"


#define MENU_BTN_CNT     6









namespace Ui {
class MainWindow;
}

class MainWindow : public QMainWindow
{
    Q_OBJECT

public:
    explicit MainWindow(QWidget *parent = nullptr);
    ~MainWindow();
signals:

public slots:
    void menu_btn_handle();
    void serial_receive_info();
    void serial_open_handle();
    void serial_close_handle();
    void serial_write_handle(QByteArray buf);

private:
    Ui::MainWindow *ui;
    
    
    
private:     
   QList <QPushButton *> menu_btn_list;
   uidesign * ui_design                         = nullptr;


   QList <QWidget * > menu_widget_list;

   SetSerialParam   * set_serial_param          = nullptr;
   SerialDebug      * serial_debug              = nullptr;
   SerialProtocol   * serial_protocol           = nullptr;
   SerialAnalyseData* serial_analyse_data       = nullptr;

   SERIAL_SET_PARAM * _serial_set_param         = nullptr;
   QSerialPort      * serial_port               = nullptr;




    
};

#endif // MAINWINDOW_H
